<?Lassoscript
// Last modified 4/17/09 by Eric Landmann

// FUNCTIONALITY
// Resolution search form

// CHANGE NOTES
// 4/17/09
// Version 1.0

// Debugging
// Var:'svDebug' = 'Y';

// Converting action_params
Var:'vError'=(Action_Param:'Error');
Var:'vSID'=(Action_Param:'SID');
?>
<form action="setup_searchresults.lasso" method="post">
	<div align="center">
		<table width="491">
			<tr>
				<td colspan="2">
					<h2>Search for Forums</h2> 
<?Lassoscript
// Standard Error Table
// If: (Var:'vError') != '2003';
If: (Var:'vError') != '';
	LI_ShowError3: -ErrNum=$vError, -Option=$vOption;
/If;
?>
				</td>
			</tr>
			<tr>
				<td width="150" bgcolor="[Var:'svSearchContentColor']" valign="middle">
					<div align="right"><strong>Forum</strong></div>
				</td>
<?Lassoscript
// Get list of Sections
Var:'vSQLSearchSections'='SELECT * FROM ' $svSectionsTable ' ORDER BY Section_Title';
Inline: $IV_SearchSections, -SQL=$vSQLSearchSections;
	'\t<td bgcolor="'($svPostContentColor)'"><select name="SID">\n';
	'\t\t<option value=""'; If: (Var:'vSID') == ''; ' selected'; /If; '>--- Show All---</option>\n';
	Records;
		'\t\t\t<option value="'(Field:'Section_ID') '"'; If: (Field:'Section_ID') == ($vSID); ' selected'; /If; '>'(Field:'Section_Title')'</option>\n';
	/Records;
	'\t\t</select>\n';
/Inline;
	?> 
				</td>
			</tr>
			<tr>
				<td colspan="2" bgcolor="[Var:'svSearchContentColor']">
					<div align="center">
						<input type="hidden" name="New" value="Y">
						<input type="hidden" name="Datatype" value="Forum">
						<input type="submit" name="-Nothing" value="Search">
					</div>
				</td>
			</tr>
		</table>
	</div>
</form>
